import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home.vue'
import login from '../views/login/index.vue'
import FriendChat from "../views/chat/FriendChat";
// import UserCenter from '../components/UserCenter.vue'

Vue.use(VueRouter);

const routes = [
    {
        path: '/',
        name: 'login',
        component: login,
        hidden: true
    },
    {
        path: '/home',
        name: 'Home',
        component: Home,
        hidden: true,
        children:[
            {
                path: '/chat',
                name: '消息',
                component: FriendChat,
                hidden: true
            },
        ]
    },
    // {
    //   path:'/userCenter',
    //   name:'UserCenter',
    //   component:UserCenter,
    //   // hidden:true
    // }
    // { path: '*', redirect: '/404', hidden: true }
]

const router = new VueRouter({
    routes
})

export default router
